<ion-view title="修改承运单">
    <ion-nav-buttons side="left">
        <button class="button back-button buttons icon ion-ios-arrow-left button-clear header-item" nav-direction="back" ng-click="goBack()">返回</button>
    </ion-nav-buttons>
    <ion-content delegate-handle="mainScroll">
        <div class="list list1 card">
            <div class="item item-input div" >
                &nbsp;<i class="input-label col-25" >承运日期：</i>
                <button class="button button-block button-clear " style="text-align: right;font-size: 14px;margin-right: 42px;color: black" ng-click="showCyrq()">{{cyd.cyrq | date : "yyyy年MM月dd日"}}</button>
            </div>
            <div class="item item-input div">
                <i class="icon ion-asterisk assertive bitian" style="margin-left: -9px"></i>承运单号：
                <input type="text" onkeyup="value=value.replace(/[^\w\-\/]/ig,'')" ng-model="cyd.cydh" class="rightTxt" maxlength="15" id="cydhCode">
            </div>
            <div class="item item-input item-select div">
                <div class="row" >
                    <i class="input-label">到达站：</i>
                    <select id="ddz" class="select">
                        <option selected></option>
                        <option ng-repeat="i in zdChoose" value="{{i.bm_id}}">{{i.bmmc}}</option>
                    </select>
                </div>
            </div>
            <div class="item item-input div">
                <div class="row" >
                    <i class="input-label " >目的地：</i>
                    <input type="text"  ng-model="cyd.mdd" class="rightTxt" maxlength="10">
                </div>
            </div>
            <div class="item item-input item-divider div" ng-click="chooseLinkman(2,1)">
                <i class="ion ion-person i balanced ti"></i>
                <i class="dark">收货人</i>
                <i class="ion ion-ios-paper-outline" style="margin-left: auto;color: #8f8f8f;margin-right: 10px;font-size: 23px;"></i>
            </div>
            <div class="item item-input div">
                <input type="text" ng-model="cyd.shrmc" placeholder="姓名" maxlength="8">
                <i style="color: #9f9f9f">丨</i>
                <input type="tel" maxlength="11" class="col-30" ng-model="cyd.shrdh" placeholder="电话" id="shrdhval" onkeyup="value=value.replace(/\D/g,'')">
            </div>
            <div class="item item-input div">
                <input type="text"  ng-model="cyd.shrdz" placeholder="地址"  maxlength="30">
            </div>
            <div class="item item-input item-divider div" ng-click="chooseLinkman(2,2)">
                <i class="ion ion-person i energized ti"></i>
                <i class="dark">发货人</i>
                <i class="ion ion-ios-paper-outline" style="margin-left: auto;color: #8f8f8f;margin-right: 10px;font-size: 23px;"></i>
            </div>
            <div class="item item-input div">
                <input type="text" ng-model="cyd.fhrmc" placeholder="姓名" maxlength="8">
                <i style="color: #9f9f9f">丨</i>
                <input type="tel" maxlength="11" class="col-30"  ng-model="cyd.fhrdh" placeholder="电话" id="fhrdhval" onkeyup="value=value.replace(/\D/g,'')">
            </div>
            <div class="item item-input div">
                <input type="text" ng-model="cyd.fhrdz" placeholder="地址" maxlength="30" >
            </div>
            <div class="item item-input item-divider div">
                <i class="ion ion-ios-list i calm ti"></i>
                <i class="dark">发货信息</i>
            </div>
            <div class="item item-input div">
                <div class="row">
                    <i class="input-label">货名：</i>
                    <input type="text"  ng-model="cyd.hwmc" class="rightTxt"  maxlength="10">
                </div>
            </div>
            <div class="item item-input div">
                <i class="icon ion-asterisk assertive bitian" style="margin-left: -9px"></i>件数：
                <input type="number" ng-model="cyd.sl" ng-change="changejian(cyd.sl)" class="rightTxt" style="margin-right: -25px" id="jian" onkeyup="this.value=this.value.replace(/\D/g,'')" onafterpaste="this.value=this.value.replace(/\D/g,'')" onkeypress="this.value = this.value.slice(0, 7)">
                <span style="color: darkgrey;margin-right: 13px;margin-top: 8px">件</span>
            </div>
            <div class="item item-input div" style="margin-left: 5px;">重量：
                <input type="number" ng-model="cyd.zl" class="rightTxt zlDot" style="margin-right: -25px"  id="zl" onkeypress="this.value = this.value.slice(0, 7)">
                <span style="color: darkgrey;margin-right: 13px;">吨</span>
            </div>
            <div class="item item-input div" style="margin-left: 5px;">体积：
                <input type="number" ng-model="cyd.tj" class="rightTxt tjDot" style="margin-right: -25px"  id="tj" onkeypress="this.value = this.value.slice(0, 7)">
                <span style="color: darkgrey;margin-right: 13px;">㎥</span>
            </div>
            <div class="item item-input div" style="height: 40px;margin-left: 5px;">包装：
                <input type="text" ng-model="cyd.bzlx" maxlength="10" class="rightTxt" style="margin-right: -30px">
                <div style="width: 40px;height: 37px;text-align: center;margin-top: 10px;" ng-click="chooseBz()">
                    <i class="ion ion-chevron-right" style="color: #9f9f9f;font-size: 13px;"></i>
                </div>
            </div>
            <div class="item item-input item-select div" >
                <div class="row  icon-left icon-right ">
                    <i class="input-label">送货方式：</i>
                    <select class="select" id="shType" >
                        <option ng-repeat="i in shfsChoose" value="{{i.code}}">{{i.name}}</option>
                    </select>
                </div>
            </div>
            <div class="item item-input item-divider div">
                <i class="ion ion-cash assertive ti"></i>&nbsp;&nbsp;&nbsp;
                <i style="height: 30px;line-height: 30px">费用:</i>
                <button class=" button-clear col-80" style="text-align: right;padding-right: 20px" ng-click="addMenu()"><i class="icon ion-plus-round dark"></i></button>
            </div>
            <div class="item item-input item-select div" >
                <div class="row  icon-left icon-right ">
                    <i class="input-label">付款方式：</i>
                    <select class="select" id="fkType" >
                        <option ng-repeat="i in fkfsChoose" value="{{i.code}}">{{i.name}}</option>
                    </select>
                </div>
            </div>
            <div class="item item-input hide div" id="xfLab">
                <div class="row">
                    <i class="input-label">现付：</i>
                    <input type="number" ng-model="cyd.yf_xf" class="rightTxt xfDot" id="yfxf" onkeypress="this.value = this.value.slice(0, 9)">
                </div>
            </div>
            <div class="item item-input hide div" id="tfLab">
                <div class="row">
                    <i class="input-label">提付：</i>
                    <input type="number" ng-model="cyd.yf_tf" class="rightTxt tfDot" id="yftf" onkeypress="this.value = this.value.slice(0, 9)">
                </div>
            </div>
            <div class="item item-input hide div" id="hfLab">
                <div class="row">
                    <i class="input-label">回付：</i>
                    <input type="number" ng-model="cyd.yf_hf" class="rightTxt hfDot" id="yfhf" onkeypress="this.value = this.value.slice(0, 9)">
                </div>
            </div>
            <div class="item item-input hide div" id="yjLab">
                <div class="row">
                    <i class="input-label">月结：</i>
                    <input type="number" ng-model="cyd.yf_yj" class="rightTxt yjDot" id="yfyj" onkeypress="this.value = this.value.slice(0, 9)">
                </div>
            </div>
            <div class="item item-input hide div" id="dkLab">
                <div class="row">
                    <i class="input-label">代扣：</i>
                    <input type="number" ng-model="cyd.yf_ycdk" class="rightTxt dkDot" id="yfdk" onkeypress="this.value = this.value.slice(0, 9)">
                </div>
            </div>
            <div class="item item-input div" id="yun" >
                <div class="row">
                    <i class="input-label">运费：</i>
                    <input type="number" ng-model="cyd.yf" id="yf" class="rightTxt numDot" ng-change="maxfy(cyd.yf)" onkeypress="this.value = this.value.slice(0, 9)">
                </div>
            </div>
            <div class="item item-input div">
                <div class="row">
                    <i class="input-label">代收货款：</i>
                    <input type="number"  ng-model="cyd.dsk_hf" class="rightTxt dshkDot"  id="dskhf" onkeypress="this.value = this.value.slice(0, 9)">
                </div>
            </div>
            <div class="item item-input div">
                <div class="row">
                    <i class="input-label">现返：</i>
                    <input type="number" ng-model="cyd.xxf_xf" class="rightTxt xxfDot"  id="xf" onkeypress="this.value = this.value.slice(0, 9)">
                </div>
            </div>
            <div class="item item-input div">
                <div class="row">
                    <i class="input-label">欠返：</i>
                    <input type="number" ng-model="cyd.xxf_qf" class="rightTxt qfDot"  id="qf" onkeypress="this.value = this.value.slice(0, 9)">
                </div>
            </div>

            <div class="item item-input hide div" on-hold="holdonRemove(1)" id="shfLab">
                <div class="row">
                    <i class="input-label">送货费：</i>
                    <input type="number" ng-model="cyd.shf1" class="rightTxt shfDot" id="shf" onkeypress="this.value = this.value.slice(0, 9)">
                </div>
            </div>
            <div class="item item-input hide div" on-hold="holdonRemove(2)" id="thfLab">
                <div class="row">
                    <i class="input-label">提货费：</i>
                    <input type="number" ng-model="cyd.thf" class="rightTxt thfDot" id="thf" onkeypress="this.value = this.value.slice(0, 9)">
                </div>

            </div>
            <div class="item item-input hide div" on-hold="holdonRemove(3)" id="beLab">
                <div class="row">
                    <i class="input-label col-33">保额：</i>
                    <input type="number"class="col-55 beDot" value="cyd.be" ng-model="cyd.be" onkeypress="this.value = this.value.slice(0, 9)">
                    <i style="margin-top: 9px">投保</i>
                    <ion-checkbox style="height: 42px;margin-top: -2px" ng-model="tbzt.isCk"></ion-checkbox>
                </div>

            </div>
            <div class="item item-input hide div" on-hold="holdonRemove(4)" id="bfLab">
                <div class="row">
                    <i class="input-label">保费：</i>
                    <input type="number" ng-model="cyd.bf" class="rightTxt bfDot" id="bf" onkeypress="this.value = this.value.slice(0, 9)">
                </div>

            </div>
            <div class="item item-input hide div" on-hold="holdonRemove(5)" id="yfdfLab">
                <div class="row">
                    <i class="input-label col-33">运费垫付：</i>
                    <input type="number" ng-model="cyd.yf_df" class="col-55 rightTxt yfdfDot" id="yfdf" onkeypress="this.value = this.value.slice(0, 9)">
                    <i style="margin-top: 9px">已返</i>
                    <ion-checkbox id="yfdfzt" style="height: 42px;margin-top: -2px" ng-model="yfdfzt.isCk"></ion-checkbox>
                </div>

            </div>
            <div class="item item-input hide div" on-hold="holdonRemove(6)" id="dskdfLab">
                <div class="row">
                    <i class="input-label col-33">代收款垫付：</i>
                    <input type="number" ng-model="cyd.dsk_xf" class="col-55 rightTxt dskdfDot"  id="dskxf" onkeypress="this.value = this.value.slice(0, 9)">
                    <i style="margin-top: 9px">已返</i>
                    <ion-checkbox style="height: 42px;margin-top: -2px" ng-model="dskdfzt.isCk"></ion-checkbox>
                </div>
            </div>
            <div class="item item-input div" style="margin-left: 5px;">回单份数：
                <input type="number" ng-model="cyd.qdfs" onkeyup="this.value=this.value.replace(/\D/g,'')" onafterpaste="this.value=this.value.replace(/\D/g,'')" class="rightTxt" style="margin-right: -25px" ng-change="changeqdfs(cyd.qdfs)" id="qdfs" onkeypress="this.value = this.value.slice(0, 2)">
                <span style="color: darkgrey;margin-right: 13px;">份</span>
            </div>
            <div class="item item-input div">
                <div class="row">
                    <i class="input-label">备注：</i>
                    <input type="text" ng-model="cyd.bz" maxlength="30">
                </div>
            </div>
        </div>
    </ion-content>
    <ion-footer-bar style="height: 50px">
        <a class="button button-positive save" id="save" ng-click="saveCyd()">保存</a>
        <a class="button button-positive print "  id="print" ng-click="connectBle()">打印</a>
    </ion-footer-bar>
</ion-view>
